package com.aqie.meet.ui.login;

import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

import com.aqie.libcommon.utils.StatusBar;
import com.aqie.meet.R;

import androidx.appcompat.app.AppCompatActivity;


public class AccountActivity extends AppCompatActivity implements View.OnClickListener  {

    private TextView mTextView;
    private Button mButtonLogin;
    private Button mButtonReg;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        StatusBar.fitSystemBar(this);
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_login_home);

        initView();
    }

    private void initView() {
        mButtonLogin = findViewById(R.id.bt_login);
        mButtonReg = findViewById(R.id.bt_reg);
        mButtonLogin.setOnClickListener(this);
        mButtonReg.setOnClickListener(this);
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.bt_login:
                startActivity(new Intent(this, LoginActivity.class));
                break;
            case R.id.bt_reg:
                startActivity(new Intent(this, RegActivity.class));
                break;
        }
    }

    /**
     * 账户Activity显示的入口
     *
     * @param context Context
     */
    public static void show(Context context) {
        Intent intent = new Intent(context, AccountActivity.class);
        intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
        context.startActivity(intent);
    }
}